package com.lt.suangua.utils;

import android.app.Activity;
import android.webkit.JavascriptInterface;

/**
 * Desc:
 * Created by chenshichao-pc
 * Date: 2023-12-11 16:38
 */
public class AndroidtoJs {
    Activity mActivity;

    public AndroidtoJs(Activity activity) {
        mActivity = activity;
    }

    @JavascriptInterface
    public void finishActivity() {
        mActivity.runOnUiThread(() -> {
            mActivity.finish();
        });
    }
}
